package com.rnkrsoft.suyan.config.server.config.entity;

import com.rnkrsoft.framework.orm.PrimaryKey;
import com.rnkrsoft.framework.orm.jdbc.*;
import com.rnkrsoft.suyan.config.internal.enums.MachineStatusEnum;
import lombok.*;
/**
 * Created by woate on 2018/5/13.
 */
@Data
@ToString(callSuper = true)
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "OPERATE_HISTORY_MACHINE", prefix = "TB")
@Comment("操作历史机器表")
public class OperateHistoryMachineEntity extends BaseEntity {
    @PrimaryKey
    @StringColumn(name = "HIS_MACHINE", nullable = false)
    @Comment("历史机器主键")
    String hisMachine;

    @StringColumn(name = "OPERATE_ID", nullable = false)
    @Comment("操作编号")
    String operateId;

    @StringColumn(name = "MACHINE_ID", nullable = false)
    @Comment("机器编号")
    String machineId;

    @StringColumn(name = "PROJECT_ID")
    @Comment("环境编号")
    String projectId;

    @StringColumn(name = "VERSION_ID")
    @Comment("版本编号")
    String versionId;

    @StringColumn(name = "ENVIRONMENT_ID")
    @Comment("环境编号")
    String environmentId;

    @StringColumn(name = "MACHINE_NAME")
    @Comment("机器名")
    String machineName;

    @StringColumn(name = "MACHINE_DESC")
    @Comment("机器描述")
    String machineDesc;

    @StringColumn(name = "SECURITY_KEY", nullable = true)
    @Comment("安全密钥")
    String securityKey;

    @NumberColumn(name = "MACHINE_STATUS", defaultValue = "1", enumClass = MachineStatusEnum.class)
    @Comment("机器状态")
    Integer machineStatus;
}
